(function() {

    /**
     * Creates namespace object to isolate specific objects from global scope
     * @param {String} path
     * @return {Object} Created namespace object
     */
    window.namespace = function(path) {
        var items = path.split('.'), currentNamespace = window;

        for (var i = 0, len = items.length; i < len; ++i) {
            var key = items[i];
            currentNamespace[key] = currentNamespace[key] || { };
            currentNamespace = currentNamespace[key];
        }

        return currentNamespace;
    };

})();
